package com.t.bricks.controller;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * 程序的主页,根据配置中的'主页文件的位置'读取文件进行返回
 */
@Controller
public class HomeController {
	
	/**
	 * 访问系统,进入主页面
	 * @param request
	 * @param response
	 * @return
	 */
	@RequestMapping(method={RequestMethod.GET, RequestMethod.POST}, value="/")
	@ResponseBody
	public String home(HttpServletRequest request, HttpServletResponse response) {
		return "这里是主页";
	}

}